
import Request from '../util/request'

export default class Order extends Request {

  // 下单产品
  getProduct(data) {
    return this.request({
      url: '/h5/order/query-product',
      data
    })
  }

  // 配送地址
  getAddress(data) {
    return this.request({
      url: '/h5/order/query-address',
      data
    })
  }

  // 远程地址
  isRemoteCity(data) {
    return this.request({
      url: '/h5/order/is-remote-city',
      data
    })
  }

  // 帐户
  getAccount(data) {
    return this.request({
      url: '/h5/order/query-account',
      data
    })
  }

  // 创建订单
  createOrder(data) {
    return this.request({
      url: '/h5/order/create-order',
      data
    })
  }

  // 订单列表
  orderList(data) {
    return this.request({
      url: '/h5/my/order/list',
      data
    })
  }

  // 取消订单
  orderDelete(data) {
    return this.request({
      url: '/h5/my/order/delete',
      data
    })
  }

  // 确认收货
  orderReceived(data) {
    return this.request({
      url: '/h5/my/order/confirm-received',
      data
    })
  }

  // 查看物流
  express(data) {
    return this.request({
      url: '/h5/my/order/express',
      data
    })
  }

}
